<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://xmlns.jcp.org/jsf/core">
    <h:outputStylesheet library="css" name="default.css"/>
    <h:head>
        <title>Mantenimiento Cursos</title>
    </h:head>
    <h:body >
        <h:form id="formAlu">
            <p:messages id="messages" showDetail="true" autoUpdate="true" closable="true" />
            <h:panelGrid columns="4" columnClasses="alinder,alinizq,alinder,alinizq">
                
                <p:outputLabel value="Alumno" for="al007" styleClass="requiredLbl" />
                <p:selectOneMenu value="#{ctrMatriculas.activeReg.nalumno}" id="al007" style="width: 250px" required="true" label="Carrera" converter="alumnosConverter">
                    <f:selectItems value="#{ctrAlumnos.vlista}" var="alumno"  
                       itemLabel="#{alumno.nombre}" itemValue="#{alumno}" />
                </p:selectOneMenu>
                <h:panelGroup/>  <h:panelGroup/>
                <h:panelGroup/>  <h:panelGroup/>  <h:panelGroup/>  <h:panelGroup/>
                <h:panelGroup/>  <h:panelGroup/>  <h:panelGroup/>  <h:panelGroup/>  
                <h:panelGroup/>  <h:panelGroup/>  <h:panelGroup/>  <h:panelGroup/>
                
                <p:commandButton actionListener="#{ctrMatriculas.save}" value="Save" id="saveAlu"  />
                <p:commandButton actionListener="#{ctrMatriculas.delete}" value="Delete" id="delAlu" rendered="#{not ctrMatriculas.lnuevo}">
                       <p:confirm header="Confirmación" message="¿Esta seguro que quiere borrar este curso?" icon="ui-icon-alert" />
                </p:commandButton>
 
                <p:confirmDialog global="true" showEffect="fade" hideEffect="fade">
                    <p:commandButton value="Si" type="button" styleClass="ui-confirmdialog-yes" icon="ui-icon-check" />
                    <p:commandButton value="No" type="button" styleClass="ui-confirmdialog-no" icon="ui-icon-close" />
                </p:confirmDialog>
           </h:panelGrid>

         </h:form>
    </h:body>
</html>



